<?php defined('G_IN_SYSTEM')or exit('No permission resources.'); ?><?php 
$f_home = '';
$f_whole = '';
$f_jiexiao = '';
$f_car = '';
$f_personal = '';
$f_shaidan = '';

if( ROUTE_C == 'home' || ROUTE_C == 'user' ){
$f_personal = 'cur';
}else if( ROUTE_C == 'mobile' && ROUTE_A == 'init'){
$f_home = 'cur';
}else if( ROUTE_C == 'mobile' && ROUTE_A == 'lottery'){
$f_jiexiao = 'cur';
}else if( ROUTE_C == 'cart'){
$f_car = 'cur';
}else if( ROUTE_C == 'shaidan'){
$f_whole = 'cur';
}
 ?>

<footer class="footer">
	<ul>
       <a href="<?php echo WEB_PATH; ?>/index.php/mobile/mobile/init">
           <li class="<?php echo $f_home; ?>">
               <img src="<?php echo G_TEMPLATES_IMAGE; ?>/wx/shouye.png" src2="<?php echo G_TEMPLATES_IMAGE; ?>/wx/shouye_click.png"><br />
               <span class="footer-name">首页</span>          
           </li>
       </a>
       
       <a href="<?php echo WEB_PATH; ?>/index.php/mobile/mobile/lottery.html">
        <li class="<?php echo $f_jiexiao; ?>">
        	<img src="<?php echo G_TEMPLATES_IMAGE; ?>/wx/zuixinjiexiao.png" src2="<?php echo G_TEMPLATES_IMAGE; ?>/wx/zuixinjiexiao_click.png"><br />
        	<span class="footer-name">最新揭晓</span> 
        </li>
    </a>
    
    <a href="<?php echo WEB_PATH; ?>/index.php/mobile/shaidan/">
        <li class="<?php echo $f_whole; ?>">
        	<img src="<?php echo G_TEMPLATES_IMAGE; ?>/wx/shaidan.png" src2="<?php echo G_TEMPLATES_IMAGE; ?>/wx/shaidan_click.png"><br />
        	<span class="footer-name">晒单</span> 
        </li>
    </a>
    
    <a href="<?php echo WEB_PATH; ?>/index.php/mobile/cart/cartlist/">
        <li class="<?php echo $f_car; ?>">
        	<img src="<?php echo G_TEMPLATES_IMAGE; ?>/wx/gouwuche.png" src2="<?php echo G_TEMPLATES_IMAGE; ?>/wx/gouwuche_click.png" class="shopping-cart"><br />
        	<span class="footer-name">购物车</span> 
        </li>
    </a>
    
    <a href="<?php echo WEB_PATH; ?>/index.php/mobile/home">
        <li class="<?php echo $f_personal; ?>">
        	<img src="<?php echo G_TEMPLATES_IMAGE; ?>/wx/wo.png" src2="<?php echo G_TEMPLATES_IMAGE; ?>/wx/wo_click.png"><br />
        	<span class="footer-name">我</span> 
        </li>
    </a>
</ul>
</footer>
<script>
    window.onload=function(){
       var src=$(".cur img").attr("src2");;
       $(".cur img").attr("src",src);	
   }
</script>